package cn.xie.domain.strategy.model.entity;

import cn.xie.domain.strategy.model.vo.RuleFillerCheckVO;
import lombok.*;

/**
 * @author: xiaoxie
 * create: 2025-08-08 16:41 
 * @BelongsProject: bit-market
 * @BelongsPackage: cn.xie.domain.strategy.model.entity
 * description: 规则动作实体
 */
// 由于有抽奖前操作,抽奖中操作,抽奖后操作
@Data
@Builder
@AllArgsConstructor
@NoArgsConstructor
public class RuleActionEntity<T extends RuleActionEntity.RaffleRuleEntity>{

    //默认允许
    private String code = RuleFillerCheckVO.ALLOW.getCode();

    private String info = RuleFillerCheckVO.ALLOW.getInfo();

    private String ruleModel;

    private T data;

    static public class RaffleRuleEntity{

    }
    @EqualsAndHashCode(callSuper = true)
    @Data
    @Builder
    @AllArgsConstructor
    @NoArgsConstructor
    // 抽奖前 黑名单和权重抽奖需要用到的属性
    static public class RaffleRuleBeforeEntity extends RaffleRuleEntity{
        private Long strategyId;

        private String ruleWeightValue;

        // 黑名单固定返回奖品100
        private Integer awardId;
    }

    // 抽奖中
    static  public class RaffleRuleCenterEntity extends RaffleRuleEntity{

    }
    // 抽奖后
    static public class RaffleRuleAfterEntity extends RaffleRuleEntity{

    }


}
